﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;
using HP.Cachalote.WPF.Model;
using HP.Cachalote.WPF.ViewModel;
using HP.Cachalote.UnitTests.FakeServices;
using System.Windows;

namespace HP.Cachalote.UnitTests.WPFTests
{
    [TestFixture]
    public class TodoLabelTreeViewModelTest
    {
        IDataService fakeDataService;
        TodoLabelTreeViewModel _todoLabelTreeViewModel;
        public int listNumber = 2;

        [SetUp]
        public void Setup()
        {
            fakeDataService = new FakeDataService();
            _todoLabelTreeViewModel = new TodoLabelTreeViewModel(fakeDataService);
        }

        [Test]
        public void GetAll()
        {
            var list = _todoLabelTreeViewModel.LabelList;
            int count = list.Count;
        }

        [Test]
        public void TestLabelList()
        {
            var list = _todoLabelTreeViewModel.LabelList;
            Assert.AreEqual(listNumber, list.Count);
        }

        //[Test]
        //public void TestSelectedItemChangedCommand()
        //{
        //    var cmd = _todoLabelTreeViewModel.SelectedItemChangedCommand;
        //    cmd.Execute(_todoLabelTreeViewModel.LabelList[0]);
        //}
    }
}